import { Link } from '@brillout/docpress'

import { UiFrameworkExtension, ProvidedBy, ConfigSpec } from '../../components'

<ConfigSpec
  env="server"
  cumulative
  global
  providedBy={<ProvidedBy noCustomGuide />}
>
```ts ts-only hide-menu
type Value = Record<string, string>
type HtmlAttributes = Value | ((pageContext) => Value)
```
</ConfigSpec>

The `htmlAttributes` setting adds attributes to the `<html>` tag.

```ts
// pages/+config.ts

import type { Config } from 'vike/types'

export default {
  // <html class="dark">
  htmlAttributes: { class: 'dark' }
} satisfies Config
```

See <Link href="/lang" /> if you merely want to set the `<html lang>` attribute.


## See also

- <Link href="/lang" />
- <Link href="/head-tags" />
- <Link href="/settings#html-shell" doNotInferSectionTitle />
